home *** CD-ROM | disk | FTP | other *** search
Text File | 1993-01-24 | 1.4 KB | 68 lines | [TEXT/AxoC] |
- LocalLanguage Pascal
- {-------------------------------------------------
- This document contains a procedure for converting
- between pA and pS, taking into account the membrane
- potential. This is a problem neuroscience researchers
- often encounter when working with single channels.
-
- pApS is equivalent to pSpA
-
- • To load these functions choose "Select All" under
- the "Edit" menu, then press "enter".
-
- --------------------------------------------------}
- Var
- mV, pA, pS: Real
-
- {• Single channel properties •}
- procedure pSpA
- Var
- done: Boolean
- begin
- done = False
- Repeat
- PoseDialog ('\rSingle Channel Properites.\rSet unknown parameter to zero',
- & 'Holding potential : mV',mV,
- & 'Channel current : pA', pA,
- & 'Channel conductance : pS', pS )
-
- if pA = 0 then { calculate single channel current in pA }
- begin
- pA = pS * mV / 1000
- done = True
- end
- else
- begin
- if mV = 0 then { calculate holding potential in mV }
- begin
- mV = pA * 1000 / pS
- done = True
- end
- else { calculate single channel conductance in pS }
- begin
- if pS = 0 then
- begin
- pS = pA * 1000 / mV
- done = True
- end
- end
- end
- if done then
- begin
- WriteLn ('Holding potential = ',mV,' mV')
- WriteLn ('Current = ',pA,' pA')
- WriteLn ('Conductance = ',pS,' pS')
- end
- else
- begin
- Alert ('No calculation was performed.\nPlease set the unknown value to zero.')
- end
- until done
- end
-
- procedure pApS
- begin
- pSpA
- end
-
-